package pong.game.objects;

import pong.game.WifiType;
import pong.general.GameWindow;
import android.graphics.Bitmap;

public class Range extends DinamicObject
{
	float		radius;
	
	boolean leaveGameZone() 
	{
		return pos.x < 0 || pos.x + width > 1.0f || 
	        	pos.y < 0 || pos.y + height > 1.0f;
	}
	
	
	
	public Range(Bitmap bitmap) 
	{
		super(bitmap);
		radius = 0;
	}
	public Range(Bitmap bitmap, WifiType wifiType, float X, float Y, float radius)
	{
		super(bitmap, wifiType, X, Y, radius*2, radius*2);
		this.radius = radius;
	}
	public Range(Bitmap bitmap, WifiType wifiType, float X, float Y)
	{
		super(bitmap, wifiType, X, Y, (float)bitmap.getHeight() / GameWindow.heightWorld,
				(float)bitmap.getWidth() / GameWindow.widthWorld);
		radius = ((float)bitmap.getHeight() / GameWindow.heightWorld) * 2;
	}


	
	
}
